package com.cdtye.itps.cms.service.equipment;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.cdtye.common.mybatiscore.base.BaseService;
import com.cdtye.itps.cms.dao.equipment.entity.EquipmentFileLog;
import com.cdtye.itps.cms.dao.equipment.vo.EquipmentFileLogVo;
import com.cdtye.itps.cms.mapper.equipment.EquipmentFileLogMapper;
import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
@Slf4j
public class EquipmentFileLogService extends BaseService<EquipmentFileLogMapper, EquipmentFileLog> {

    @Autowired
    private EquipmentFileLogMapper modelMapper;

    /**
     * 列表查询
     * @param vo
     * @return
     */
    public List<EquipmentFileLog> list(EquipmentFileLogVo vo){
        LambdaQueryWrapper<EquipmentFileLog> wrapper = new LambdaQueryWrapper<>();
        //添加查询条件

        return list(wrapper);
    }

    /**
     * 分页查询，自定义sql语句
     * @param vo
     * @return
     */
    public IPage<Map<String,Object>> listPage(EquipmentFileLogVo vo){
        return modelMapper.list(vo.page(), vo);
    }

}
